package com.hanson.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hanson.pojo.vo.TbIpList;

import java.io.Serializable;
import java.util.List;

/**
 * <p>
 * ip黑白名单 服务类
 * </p>
 *
 * @author HansonLee
 * @since 2022-08-31
 */

public interface ITbIpListService extends IService<TbIpList> {


    /**
     *
     * 分页查询tbIpList
     *
     * @param condition    数据筛选条件
     * @param page      分页对象
     * @return {@link Page< TbIpList>}      传进来的分页对象，封装了查询数据结果集
     * @author HansonLee
     * @date 2022-08-31
     **/
    public Page<TbIpList> list(String condition, Page<TbIpList> page);

    /**
     *
     * 添加新tbIpList
     *
     * @param tbIpList      需要添加的tbIpList
     * @return {@link Object}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public int add(TbIpList tbIpList);

    /**
     *
     * 根据条件更新tbIpList
     *
     * @param condition     新数据以及更新条件，使用tbIpList实体类封装
     * @return {@link Object}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public int update(TbIpList condition);

    /**
     *
     * 根据条件删除tbIpList
     *
     * @param condition     删除条件，使用tbIpList实体类封装
     * @return {@link Object}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public int delete(TbIpList condition);

    /**
     *
     * 根据id删除tbIpList
     *
     * @param id     删除条件，需要删除的id
     * @return {@link int}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public int deleteById(Serializable id);

    /**
     *
     * 根据条件查询一条tbIpList
     *
     * @param condition     查询条件
     * @return {@link TbIpList}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public TbIpList selectOne(TbIpList condition);

    /**
     *
     * 根据id查询tbIpList
     *
     * @param id     id
     * @return {@link TbIpList}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public TbIpList selectById(Serializable id);

    /**
     *
     * 根据条件查询tbIpList
     *
     * @param condition     查询条件
     * @return {@link List<TbIpList>}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public List<TbIpList> selectList(TbIpList condition);

    /**
     *
     * 根据条件统计tbIpList
     *
     * @param condition     统计条件
     * @return {@link Integer}
     * @author HansonLee
     * @date 2022-08-31
     **/
    public Integer selectCount(TbIpList condition);
}
